home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c-part1 / 6073 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.2 KB

  1. Path: varian.com!usenet
  2. From: Michael.Diack@ukos.varian.com (Mike Diack)
  3. Newsgroups: comp.lang.c
  4. Subject: Re: calling a DOS TSR from C (to Dmpeter and others!!!!!)
  5. Date: 22 Feb 1996 14:52:22 GMT
  6. Organization: Varian Oncology Systems (Crawley)
  7. Message-ID: <4ghvv6$9i4@falcon.varian.com>
  8. Reply-To: Michael.Diack@ukos.varian.com
  9. NNTP-Posting-Host: duck.ukos.varian.com
  10. X-Newsreader: IBM NewsReader/2 v1.2.5
  11.  
  12. To dmpeter and other's
  13.  
  14. I know it's not an entirely relevant question to this group, but:
  15.  
  16. The "system" function call under all DOS C compilers I've seen is only
  17. designed to handle transient (non TSR) programs, ie. that load,
  18. claim memory, use memory, release the memory and terminate, in order 
  19. to avoid disrupting the memory map of the program making the system
  20. call to run the TSR/program in question.
  21.  
  22. Thus since a TSR doesn't leave memory in the same way as it was when
  23. the TSR was invoked (cos it's staying resident), you shouldn't be surprised
  24. when your mem map goes awry after invoking such an application.
  25. (the tsr is holding onto it's memory, and anyother RAM used to change the
  26. active program context, which for DOS, is probably most of the RAM used
  27. by command.com, ie. 20-50 KB approx)
  28.  
  29. Mike Diack
  30.  
  31. Michael.Diack@ukos.varian.com
  32.